package com.itcast.gameforum.mapper;

import com.itcast.gameforum.entity.Mainposts;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Options;
import org.apache.ibatis.annotations.Update;

/**
 * <p>
 *  Mapper 接口
 * </p>
 *
 * @author 647zyzlq
 * @since 2020-10-26
 */
public interface MainpostsMapper extends BaseMapper<Mainposts>
{
        @Insert("insert into mainposts(zoneid,postsnumber,name,userid,created) values(#{zoneid},#{postsnumber},#{name},#{userid},#{created})")
        @Options(useGeneratedKeys = true, keyProperty = "id")
        int saveMainPost(Mainposts mainposts);
}
